package com.changgou.goods.service.impl;

import com.changgou.goods.dao.CategoryMapper;
import com.changgou.goods.service.CategoryService;
import com.changgou.goods.pojo.Category;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import tk.mybatis.mapper.entity.Example;

import java.util.List;
import java.util.Map;

@Service
public class CategoryServiceImpl implements CategoryService {

    @Autowired
    private CategoryMapper categoryMapper;


    /**
     * @param id
     * @return com.changgou.goods.pojo.Category
     * @description: 根据分类id查询数据
     * @author 大佬味的小男孩
     * @date 2020/07/27 21:43
    */
    @Override
    public Category findById(Integer id) {
        return  categoryMapper.selectByPrimaryKey(id);
    }
}
